/*
 * Copyright (c) 2023, 2024,yzc.cn All rights reserved.
 *
 */
package com.by.controller;

import com.by.common.bean.Result;
import com.by.pojo.PurInquiry;
import com.by.server.PurInquiryServer;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>Project: erp-cloud-api - PurInquiryController</p>
 * <p>Powered by yzc On 2024-01-10 15:20:16</p>
 * <p>描述：<p>
 *
 * @author yzc [yzc0415@126.com]
 * @version 1.0
 * @since 17
 */
@RestController
@RequestMapping("/v1/pur")
@Api(tags = "询价管理")
public class PurInquiryController {

    @Autowired
    PurInquiryServer purInquiryServer;

    @PostMapping("/inquiry/save")
    public Result save(@RequestBody PurInquiry purInquiry){
        int rs = purInquiryServer.save(purInquiry);
        if (rs>0)
            return Result.success("询价单保存成功");
        return Result.error("询价单保存失败");

    }

}
